home *** CD-ROM | disk | FTP | other *** search
/ PC Play 129 / pc play 129.iso / Demo / man2 / man2.exe / data / scripts / oldunits_neweffects / oldunits_neweffects_plazmaball_fly2.lua < prev    next >
Encoding:
Text File  |  2006-02-27  |  1.1 KB  |  43 lines

  1.  
  2. function plazmaball_fly2()
  3.     local explosion = uniGetExecutor()
  4.     explosion:setTransformOwner()
  5.     local mshot1 = explosion:addSimpleEffect(ENET_EFFECT_PS_NEWPLAZMABALL2)
  6.     local light = explosion:addSimpleEffect(ENET_EFFECT_NEWPLAZMABALL_LIGHTSPOT)
  7.     waitDeath(explosion:parabolicFly(uniGetTarget()))
  8.     mshot1:suspendedDestroy(5.0)
  9.     local exp_ps = explosion:addSimpleEffect(ENET_EFFECT_PS_NEWPLAZMABALLEXPLOSION)
  10.     uniGetTarget():executeCommand(ENC_DAMAGED)
  11.     --pause(1.0)
  12.     exp_ps:suspendedDestroy(5.0)
  13.     light:destroy()
  14.     pause(3.0)
  15.     explosion:destroy()
  16. end
  17.  
  18. registerCommand(ENSCRIPTSET_NEWPLAZMABALL2,ENC_FIRE1,"plazmaball_fly2")
  19.  
  20. --
  21. -- dummy effect creation test
  22. --
  23. desc = getEffectDescriptionP(ENET_EFFECT_PS_NEWPLAZMABALL_FLY2)
  24. desc.ClassID = ENCLASS_DUMMY
  25. desc.EffectClassType = ENECT_GEOMETRY
  26.  
  27. desc.ScriptSet = ENSCRIPTSET_NEWPLAZMABALL2
  28. desc.RelativePosition = ENLOCALPOS_NOTSPECIFIED
  29. local vzbzd1 = D3DXVECTOR3:new(0,0,0)
  30. desc.LocalPosition = vzbzd1
  31. vzbzd1:delete()
  32. desc.MoveType = ENMOVE_FLY
  33.  
  34. desc.ActivityType = ENACT_COMMANDSEMIACTIVE
  35. --
  36. -- end dummy effect creation test
  37. --
  38.  
  39.  
  40.  
  41.  
  42.  
  43.